package app

import "github.com/gin-gonic/gin"

/**
 * Created with IntelliJ IDEA.
 * User: 令狐飞侠
 * Date: 2021-11-29
 * Description: gin hello world
 */

func TestHelloWorld() {
	router := gin.Default()
	router.GET("/", func(context *gin.Context) {
		context.JSON(200, gin.H{
			"message": "hello world!",
		})
	})
	//启动端口8080的服务
	router.Run(":8080")
}
